echo off

cd Sustainalytics.AdminInterface.Node\

echo ----------------------------------------
echo install npm modules for AdminInterface.Node
call npm install

echo ----------------------------------------
echo compile AdminInterface.Node\gruntfile.ts to javascript
call tsc gruntfile.ts --module CommonJS

echo ----------------------------------------
echo run grunt for AdminInterface.Node
call grunt

cd ..\Sustainalytics.ClientInterface.Node\

echo ----------------------------------------
echo install npm modules for ClientInterface.Node
call npm install

echo ----------------------------------------
echo compile ClientInterface.Node\gruntfile.ts to javascript
call tsc gruntfile.ts --module CommonJS

echo ----------------------------------------
echo run grunt for ClientInterface.Node
call grunt

cd ..\Sustainalytics.Core.Node\

echo ----------------------------------------
echo compile Core.Node\app.ts to javascript
call tsc app.ts --module CommonJS

echo ----------------------------------------
echo run Core.Node\app.js
call node app.js

cd ..

echo ----------------------------------------
echo finished
